<extend name="Public/base"/>

<block name="body">
    <!-- 标题栏 -->
    <div class="main-title">
        <h2>进件详情</h2>
    </div>
    <!-- 数据列表 -->
    <style>
        td {
            border: 1px solid black;
        }

        .one {
            width: 30%;
        }
       table input{
            width: 300px;
        }
    </style>
    <form action="{:U('Order/send_to_ms')}" method="post">
        <div class="data-table">
            <div class="data-table table-striped">
                <table>
                    <tbody>
                    <tr>
                        <td class="one">借款人姓名：</td>
                        <td class="two"><input value="{$orderb.cname}" name="base[cname]"></td>
                    </tr>
                    <tr>
                        <td class="one">联系电话：</td>
                        <td class="two"><input value="{$orderb.mobile_tel}" name="base[mobile_tel]"></td>
                    </tr>
                    <tr>
                        <td class="one">身份证：</td>
                        <td class="two"><input value="{$orderb.cid}" name="base[cid]"></td>
                    </tr>
                    <tr>
                        <td class="one">银行卡号：</td>
                        <td class="two"><input value="{$orderb.bank_card_id}" name="base[bank_card_id]"></td>
                    </tr>
                    <tr>
                        <td class="one">公司座机：</td>
                        <td class="two"><input value="{$orderb.company_tel}" name="base[company_tel]"></td>
                    </tr>
                    <tr>
                        <td class="one">家庭座机：</td>
                        <td class="two"><input value="{$orderb.home_tel}" name="base[home_tel]"></td>
                    </tr>
                    <tr>
                        <td class="one">QQ号：</td>
                        <td class="two"><input value="{$orderb.qq}" name="base[qq]"></td>
                    </tr>
                    <tr>
                        <td class="one">电子邮箱：</td>
                        <td class="two"><input value="{$orderb.email}" name="base[email]"></td>
                    </tr>
                    <tr>
                        <td class="one">学历：</td>
                        <td class="two"><input value="{$orderb.edu}" name="base[edu]"></td>
                    </tr>
                    <tr>
                        <td class="one">婚姻状况：</td>
                        <td class="two"><input value="{$orderb.mar}" name="base[mar]"></td>
                    </tr>
                    <tr>
                        <td class="one">房产状况：</td>
                        <td class="two"><input value="{$orderb.hp}" name="base[hp]"></td>
                    </tr>
                    <tr>
                        <td class="one">房产类型：</td>
                        <td class="two"><input value="{$orderb.ht}" name="base[ht]"></td>
                    </tr>
                    <tr>
                        <td class="one">户籍地址：</td>
                        <td class="two"><input value="{$orderb.cr_addr}" name="base[cr_addr]"></td>
                    </tr>
                    <tr>
                        <td class="one">家庭住址：</td>
                        <td class="two"><input value="{$orderb.home_addr}" name="base[home_addr]"></td>
                    </tr>
                    <tr>
                        <td class="one">通讯地址：</td>
                        <td class="two"><input value="{$orderb.postal_addr}" name="base[postal_addr]"></td>
                    </tr>
                    <tr>
                        <td class="one">职业：</td>
                        <td class="two"><input value="{$orderb.profession}" name="base[profession]"></td>
                    </tr>
                    <tr>
                        <td class="one">申请人类别：</td>
                        <td class="two"><input value="{$orderb.ctype}" name="base[ctype]"></td>
                    </tr>
                    <tr>
                        <td class="one">工作时间：</td>
                        <td class="two"><input value="{$orderb.worktime}" name="base[worktime]"></td>
                    </tr>
                    <tr>
                        <td class="one">工作单位：</td>
                        <td class="two"><input value="{$orderb.company_name}" name="base[company_name]"></td>
                    </tr>
                    <tr>
                        <td class="one">工作地址：</td>
                        <td class="two"><input value="{$orderb.company_addr}" name="base[company_addr]"></td>
                    </tr>
                    <tr>
                        <td class="one">公司行业：</td>
                        <td class="two"><input value="{$orderb.industry}" name="base[industry]"></td>
                    </tr>
                    <tr>
                        <td class="one">公司性质：</td>
                        <td class="two"><input value="{$orderb.company_type}" name="base[company_type]"></td>
                    </tr>
                    <tr>
                        <td class="one">职位：</td>
                        <td class="two"><input value="{$orderb.position}" name="base[position]"></td>
                    </tr>
                    <tr>
                        <td class="one">年收入：</td>
                        <td class="two"><input value="{$orderb.aincome}" name="base[aincome]"></td>
                    </tr>
                    <tr>
                        <td class="one">其他平台借款：</td>
                        <td class="two"><input value="{$orderb.if_one}" name="base[if_one]"></td>
                    </tr>
                    <tr>
                        <td class="one">其他平台负债：</td>
                        <td class="two"><input value="{$orderb.if_two}" name="base[if_two]"></td>
                    </tr>
                    <tr>
                        <td class="one">是否核实：</td>
                        <td class="two"><input value="{$orderb.if_three}" name="base[if_three]"></td>
                    </tr>

                    <tr>
                        <td class="one">借款金额：</td>
                        <td class="two"><input value="{$ordera.amount}" name="amount[amount]">元</td>
                    </tr>
                    <tr>
                        <td class="one">借款期限：</td>
                        <td class="two"><input value="{$ordera.duration}" name="amount[duration]">月</td>
                    </tr>
                    <tr>
                        <td class="one">借款日期：</td>
                        <td class="two"><input value="{$ordera.date}" name="amount[date]"></td>
                    </tr>
                    <tr>
                        <td class="one">借款用途：</td>
                        <td class="two"><input value="{$ordera.purpose}" name="amount[purpose]"></td>
                    </tr>
                    <tr>
                        <td class="one">进件省份：</td>
                        <td class="two"><input value="{$ordera.province}" name="amount[province]"></td>
                    </tr>
                    <tr>
                        <td class="one">进件城市：</td>
                        <td class="two"><input value="{$ordera.city}" name="amount[city]"></td>
                    </tr>
                    <tr>
                        <td class="one">进件渠道：</td>
                        <td class="two"><input value="{$ordera.channel}" name="amount[channel]"></td>
                    </tr>

                    <volist name="orderc" id="var">
                        <tr>
                            <td class="one" style="background-color: black">第{$var.num}联系人</td>
                            <td class="two"></td>
                        </tr>
                        <input type="hidden" name="contcts[{$var.num}][num]" value="{$var.num}">
                        <tr>
                            <td class="one">姓名：</td>
                            <td class="two"><input value="{$var.name}" name="contcts[{$var.num}][name]"></td>
                        </tr>
                        <tr>
                            <td class="one">身份证：</td>
                            <td class="two"><input value="{$var.cid}" name="contcts[{$var.num}][cid]"></td>
                        </tr>
                        <tr>
                            <td class="one">手机号：</td>
                            <td class="two"><input value="{$var.tel}" name="contcts[{$var.num}][tel]"></td>
                        </tr>
                        <tr>
                            <td class="one">社会关系：</td>
                            <td class="two"><input value="{$var.srelations}" name="contcts[{$var.num}][srelations]"></td>
                        </tr>
                        <tr>
                            <td class="one">家庭住址：</td>
                            <td class="two"><input value="{$var.home_addr}" name="contcts[{$var.num}][home_addr]"></td>
                        </tr>
                        <tr>
                            <td class="one">工作单位：</td>
                            <td class="two"><input value="{$var.work_addr}" name="contcts[{$var.num}][work_addr]"></td>
                        </tr>
                        <tr>
                            <td class="one">单位地址：</td>
                            <td class="two"><input value="{$var.company_addr}" name="contcts[{$var.num}][company_addr]"></td>
                        </tr>
                    </volist>
                    <tr>
                        <td class="one" style="background-color: black">附件</td>
                        <td class="two"></td>
                    </tr>
                    <volist name="pics" id="var">
                        <tr>
                            <td class="one"></td>
                            <td class="two"><img width="50%" src="http://ms.jinqinuo.com/Uploads/jqn/{$var.filename}"></td>
                        </tr>
                    </volist>
                    </tbody>
                </table>
                <div style="height: 10px;width: auto"></div>
                <input type="hidden" name="oid" value="{$orderb.id}">
                <h2>收费确认：</h2>
                <empty name="orderb.pay">
                    <input type="checkbox" name="base[pay]" value="已收费">已收费
                    <else />
                    已收费
                </empty>
                <hr/>
                <h2>面审回复：</h2>
                {$orderb.fail_reason}
                <div style="height: 10px;width: auto"></div>
                <hr/>

                <h2>备注:(面审以上可见)</h2>
                <textarea name="note">{$note}</textarea>
                {:hook('adminArticleEdit', array('name'=>'note','value'=>$note))}
                <!--
                <button class="btn ajax-post confirm" url="/index.php?s=/Admin/Menu/del.html" target-form="ids">
                    确认信息，提交到下一步
                </button>
                <button class="btn ajax-post confirm" url="/index.php?s=/Admin/Menu/del.html" target-form="ids">
                    确认信息，提交到下一步
                </button>
                -->
                <hr>
                <notempty name="orderb.last_amount">
                    <h2>预审金额：</h2>
                    {$orderb.last_amount}元

                    <h2>预审期限：</h2>
                    {$orderb.last_duration}月
                    <div style="height: 10px;width: auto"></div>
                </notempty>
                <input type="submit" name="sub" value="确认信息，提交到面审" class="btn">
                <if condition="$orderb.status eq 31">
                    <a class="btn confirm ajax-get" style="background-color: #7b66ab" href="{:U('Order/do_contract','oid='.$orderb['id'])}">确认，合同准备</a>
                </if>
                <if condition="$orderb.status eq 32">
                    <a class="btn confirm ajax-get" style="background-color: red" href="{:U('Order/do_fail','oid='.$orderb['id'])}">确认审核失败</a>
                </if>
            </div>
        </div>
    </form>
</block>

<block name="script">
    <script type="text/javascript">
        $(function () {
            //搜索功能
            $("#search").click(function () {
                var url = $(this).attr('url');
                var query = $('.search-form').find('input').serialize();
                query = query.replace(/(&|^)(\w*?\d*?\-*?_*?)*?=?((?=&)|(?=$))/g, '');
                query = query.replace(/^&/g, '');
                if (url.indexOf('?') > 0) {
                    url += '&' + query;
                } else {
                    url += '?' + query;
                }
                window.location.href = url;
            });

            //回车自动提交
            $('.search-form').find('input').keyup(function (event) {
                if (event.keyCode === 13) {
                    $("#search").click();
                }
            });

        })
    </script>
</block>
